package cn.cycleif.entity;

import cn.cycleif.enums.UserStatusEnum;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.time.LocalDateTime;

/**
 * @Date: 25/1/21-16:31
 * @Desc:
 */

@Data
@NoArgsConstructor
@AllArgsConstructor
public class User {
  @TableId(type = IdType.ASSIGN_ID)
  private Integer        id;
  private String         username;
  private String         displayName;
  private String         password;
  private String         avatar;
  private String         mail;
  private String         intro;
  private UserStatusEnum status;
  private LocalDateTime  lastLoginAt;
  private LocalDateTime  suspendAt;
  private LocalDateTime  suspendUntil;
  @TableField(fill = FieldFill.INSERT)
  private LocalDateTime  createAt;
  @TableField(fill = FieldFill.UPDATE)
  private LocalDateTime  updateAt;
  private Integer        followCount;
  private Integer        answerCount;
  private Integer        questionCount;
  private Integer        ranks;

}
